<template>
  <div class="model_box">
    父组件
    <span ref="spanref">{{ formData }}</span>
    <VModelChild  v-model:formData="formData" />
    <button @click="handleTT">submit</button>
  </div>
</template>

<script setup>
import { reactive } from 'vue';
import VModelChild from '../components/ModelChild.vue';
let formData=reactive({
  name:'erert',
  age:'erert',
  hop:'etttt'
});

const handleTT=()=>{
 console.log('提交的表单结果',formData);
};
</script>

<style lang="scss" scoped>
@use "@/styles/mixin" as Minxs;
.model_box {
  @include Minxs.mainWidth;
  background-color: #f2f2f2;
  padding: 16px;
}
</style>
